package com.ztgf.shopping.models.dto.shop;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotations.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ztgf.common.dto.BaseDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 店铺平台开票DTO
 *
 * @author liyang
 * @Date 2021-05-26 12:08:14
 */
@Data
@TableName("shop_sys_invoice")
@ApiModel(value="店铺平台开票对象", description="店铺平台开票对象")
public class ShopSysInvoiceDTO extends BaseDTO implements Serializable {

    @ApiModelProperty(value = "乐观锁")
    private Integer revision;
    @ApiModelProperty(value = "创建人")
    private Long createUserId;
    @ApiModelProperty(value = "更新人")
    private Long updateUserId;
    @ApiModelProperty(value = "平台开票表id")
    private Long sysInvoiceId;
    @ApiModelProperty(value = "订单id")
    private Long orderId;
    @ApiModelProperty(value = "开票状态 0已开票，1未开票")
    private Integer status;
    @ApiModelProperty(value = "类型 0物流费，1佣金，2砍价固定技术服务费，3砍价佣金")
    private Integer type;
    @ApiModelProperty(value = "金额")
    private BigDecimal price;
    @ApiModelProperty(value = "卖家id ，或者买家id")
    private Long shopId;
    @ApiModelProperty(value = "订单编号")
    private String orderNo;
    @ApiModelProperty(value = "费用名称")
    private String name;
    @ApiModelProperty(value = "扣费时间")
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")//gosn
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")//输入字符串
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")//fastjson
    private Date deductTime;
    @ApiModelProperty(value = "状态：0买家，1卖家")
    private Integer sellOrBuyType;
    @ApiModelProperty(value = "商品报价表id")
    private Long purchaseCommodityBargainId;
    @ApiModelProperty(value = "订单商品关系表id")
    private Long orderCommodityRelationId;
    @ApiModelProperty(value = "采购信息表id")
    private Long purchaseId;
    @ApiModelProperty(value = "订单状态表id")
    private Long orderStatusId;
}